package com.jzo2o.market.controller.operation;

import com.jzo2o.common.model.PageResult;
import com.jzo2o.market.model.dto.request.CouponOperationPageQueryReqDTO;
import com.jzo2o.market.model.dto.response.CouponInfoResDTO;
import com.jzo2o.market.service.ICouponService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * 优惠券记录控制层
 *
 * @Author mr.fu
 * @Date 2025/2/8 14:44
 */
@RestController("operationCouponController")
@RequestMapping("/operation/coupon")
@Api(tags = "优惠券记录处理类")
public class CouponController {

    @Autowired
    private ICouponService couponService;

    @GetMapping("/page")
    @ApiOperation("查询优惠券领取记录列表")
    public PageResult<CouponInfoResDTO> pageList(CouponOperationPageQueryReqDTO dto) {
        return couponService.pageList(dto);
    }
}
